/* 重置默认样式 */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  -webkit-user-select: none; /* 防止文本选择 */
}

.app {
  width: 100vw;
  height: 100vh;
  display: flex;
  flex-direction: column;
  background-color: #1e1e1e;
  overflow: hidden;
}

/* 标题栏样式 */
.title-bar {
  height: 32px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  background-color: #2d2d2d;
  -webkit-app-region: drag; /* 使整个标题栏可拖动 */
  user-select: none;
}

.title-bar-drag-area {
  padding-left: 12px;
  font-size: 12px;
  -webkit-app-region: drag; /* 确保标题文本区域可拖动 */
}

.window-controls {
  display: flex;
  -webkit-app-region: no-drag; /* 窗口控制按钮不可拖动 */
}

.window-controls button {
  width: 46px;
  height: 32px;
  border: none;
  background: transparent;
  color: #fff;
  font-size: 16px;
  cursor: pointer;
  transition: background-color 0.2s;
  -webkit-app-region: no-drag; /* 确保按钮可点击 */
}

.window-controls button:hover {
  background-color: rgba(255, 255, 255, 0.1);
}

.window-controls button:last-child:hover {
  background-color: #e81123;
}

/* 主内容区域样式 */
.main-content {
  flex: 1;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  background-color: #1e1e1e;
}

/* 允许画布区域选择文本 */
.canvas-container {
  -webkit-user-select: auto;
}

/* 允许工具栏按钮点击 */
.toolbar button {
  -webkit-app-region: no-drag;
}

.toolbar {
  height: 40px;
  background-color: rgba(40, 40, 40, 0.95);
  display: flex;
  align-items: center;
  padding: 0 12px;
  gap: 8px;
}

.layer-panel {
  width: 240px;
  background-color: #f5f5f5;
  border-left: 1px solid #e0e0e0;
  padding: 16px;
} 